<div class="main_content">
	<table width="98%" name="tab_main" id="tab_main" class="tab_main" border="0" cellpadding="0" cellspacing="1" align="left">
	<thead>
		<tr>
			<th>序号</th>				
			<th>合同编号</th>
			<!--<th>批复单号</th>-->
			<th>合同总价</th>
			<th>币种</th>
			<th>供应商</th>
			<th>谈判人</th>
			<th>谈判日期</th>
			<th>签订合同日期</th>
			<th>签订到货日期</th>
			<th>合同备注</th>
			<th>操作</th>
		</tr>
	</thead>
	<tbody>
	{%foreach from=$arr  key=key item=arr_item%}
		<tr class="list_{%$key+1%}">
			<td>
				{% if $v_mc_info[$arr_item.contract_no] %}
					<div id="sign_{%$key+1%}" class="sign_pm pcursor sign_plus" onclick="showList(this,{%$key+1%})"></div>
				{% else %}
					<div class="sign_pm sign_minus"></div>
				{% /if %}
			</td>
			<td>{%$arr_item.contract_no%}</td>
			<!--<td>{%$arr_item.plan_reply_no%}</td>-->
			<td>{%$arr_item.contract_prices%}</td>
			<td>{%$price_type_arr[$arr_item.currency_id]%}</td>
			<td>{%$arr_item.sell_owner%}</td>
			<td>{%$admin_info[$arr_item.admin_user_id]%}</td>
			<td>{%$arr_item.talks_time|date_format:"%Y-%m-%d"%}</td>
			<td>{%$arr_item.contract_time|date_format:"%Y-%m-%d"%}</td>
			<td>{%$arr_item.finish_time|date_format:"%Y-%m-%d"%}</td>
			<td>{%$arr_item.contract_info%}</td>
			<td>
			<a href='index.php?c=zy_mc_auth&m=add&contract_no={%$arr_item.contract_no%}'>验收</a>&nbsp;&nbsp;
			</td>
		</tr>
		<tr class="hide_chunk">
			<td colspan="11">
				<div class="arrow_open"></div>
				
				<div class="load_list">
					<table width="96%" name="tab_sub" id="tab_sub" class="tab_sub" border="0" cellpadding="0" cellspacing="1" align="left">
					<thead>
						<tr>
							<th>序号</th>
							<th>中文名称</th>
							<th>英文名称</th>
							<th>规格型号</th>
							<th>数量</th>
							<td>单价</td>
							<th>总价</th>
							<th>所属项目</th>
							<th>设备备注</th>
							<th>操作</th>
						</tr>
					</thead>
					<tbody>	
					{%if $v_mc_info[$arr_item.contract_no]%}
						{%foreach item=list from=$v_mc_info[$arr_item.contract_no]%}
						<tr class="show_two">
							<td>
								{% if $v_mc_info_log[$arr_item.contract_no][$list.sell_reply_id] %}
									<div id="sign_{%$list.sell_reply_id%}" class="sign_pm pcursor sign_plus" onclick="showList_two(this,{%$list.sell_reply_id%})"></div>
								{% else %}
									<div class="sign_pm sign_minus"></div>
								{% /if %}
							</td>
							<td>{%$list.mc_cn_name%}</td>
							<td>{%$list.mc_en_name%}</td>
							<td>{%$list.mc_type_model%}</td>
							<td>{%$list.plan_no%}</td>
							<td>{%$list.make_cost%}</td>
							<td>{%$list.make_cost+$list.manage_cost+$list.vat%}</td>
							<td>{%$project_arr[$list.project_id]%}</td>
							<td>{%$list.mc_info%}</td>
							<td>
							{%if $list.is_p_mc == 1%}
								<a href='index.php?c=zy_mc_log&m=add&sell_reply_id={%$list.sell_reply_id%}'>添加设备记录</a>&nbsp;&nbsp;
							{%/if%}
							</td>
						</tr>
						<tr class="hide_chunk">
								<td colspan="10">
									<div class="arrow_open"></div>
									
									<div class="load_list">
										<table width="96%" name="tab_sub" id="tab_sub" class="tab_sub" border="0" cellpadding="0" cellspacing="1" align="left">
											<thead>
												<tr>
													<th>中文名称</th>
													<th>英文名称</th>
													<th>规格型号</th>
													<th>数量</th>
													<th>单位</th>
													<th>单价</th>
													<th>总价</th>
													<!--<th>所属项目</th>-->
													<th>到货状态</th>
													<th>到货期间</th>
													<th>到货地点</th>
													<!--<th>设备备注</th>-->
													<th>操作</th>
												</tr>
											</thead>
											<tbody>	
												{% if $v_mc_info_log[$arr_item.contract_no][$list.sell_reply_id] %}
													{%foreach item=list_two from=$v_mc_info_log[$arr_item.contract_no][$list.sell_reply_id]%}
													<tr>
														<td>{%$list_two.mc_cn_name%}</td>
														<td>{%$list_two.mc_en_name%}</td>
														<td>{%$list_two.mc_model%}</td>
														<td>{%$list_two.mc_no%}</td>
														<td>{%$list_two.unit%}</td>
														<td>{%$list_two.price%}</td>
														<td>
														{%if $list_two.price > 0 && $list_two.mc_no > 0%}
															{% $list_two.price*$list_two.mc_no%}
														{%else%}
															暂无
														{%/if%}
														</td>
														<!--<td>{%$project_arr[$list.project_id]%}</td>-->
														<td>
														{%if $list_two.arrival_state%}
															已到货
														{%else%}
															未到货
														{%/if%}
														</td>
														<td>{%$arr_item.finish_time|date_format:"%Y-%m-%d"%}</td>
														<td>
														{%if $list_two.arrival_area%}
															{%$list_two.arrival_area%}
														{%else%}
															暂无
														{%/if%}
														</td>
													<!--	<td>{%$list.mc_info%}</td>-->
														<td>
														<a href='index.php?c=zy_arrival_log&m=add&mc_log_id={%$list_two.mc_log_id%}'>添加到货记录</a>&nbsp;&nbsp;
														<a href='index.php?c=zy_mc_log&m=edit&mc_log_id={%$list_two.mc_log_id%}'>修改</a>&nbsp;&nbsp;
														</td>
													</tr>
													{%/foreach%}
												{%/if%}
											</tbody>										
										</table>
									</div>
								</td>
							</tr>
						{%/foreach%}
					{%/if%}
					</tbody>					
					</table>
				</div>
			</td>
		</tr>
	{%/foreach%}
	</tbody>
		{%if $arr %}
		<tfoot>
			<tr>
				<td colspan="11"><div id="pager">{%$page_footer%}</div></td>
			</tr>
		</tfoot>
		{%/if%}
	</table>
	
	<div class="btn_list">
		<span class="btn_add" onclick="location.href='?c=zy_sell&m=add'">添 加</span>
	</div>	
</div>
